﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Company_rg.aspx.cs" Inherits="HomePage_Company_rg" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>企业注册</title>
    <link href="../styles/global.css" rel="stylesheet" type="text/css" />

    <script type="text/javascript">
        function test() {
            var aa = document.getElementById("Tuser").value;
            //alert(aa);
            var oHttpReq = new ActiveXObject("MSXML2.XMLHTTP");
            var oDoc = new ActiveXObject("MSXML2.DOMDocument");

            oHttpReq.open("POST", "ComputerTest.aspx?uname=" + encodeURI(aa), false);         //调用查询数据的页面，将名称传递过去
            oHttpReq.send("");
            result = oHttpReq.responseText;
            oDoc.loadXML(result);
            if (oDoc.text != ""  && oDoc.selectNodes("//Company_Blacklist/Table/Column1")[0].text == '1') {
                div1.style.display = "block";
                div1.innerHTML = "该用户名已经存在了！";
                document.getElementById("Label1").innerHTML = '';

            }
            else {
                div1.style.display = "none";
                document.getElementById("Label1").innerHTML = ' <span style="color:Red"><%=getcode() %></span> &nbsp;&nbsp;（此识别码需牢记，提交纸质资料时需同时提交！）';

            }
        }
    </script>

    <script src="../Common/yz.js" type="text/javascript"></script>

    <style type="text/css">
        body
        {
            margin: 0px;
            padding: 0px;
        }
        #container
        {
            width: 900px;
            margin: 0 auto;
            padding: 0px;
        }
        #title
        {
            float: left;
            width: 900px;
            margin: 10px auto 0px;
            padding: 0px;
            height: 80px;
        }
        #img
        {
            float: left;
            margin: 0px 0px 0px 10px;
        }
        #logo
        {
            float: left;
            padding: 20px 0px 0px 20px;
            border-bottom: 3px solid #1183c2;
            width: 700px;
        }
        #infor
        {
            width: 900px;
            float: left;
            margin: 10px 0px 0px 30px;
            float: left;
            font-size: 14px;
            font-weight: bold;
            color: #FF0000;
        }
        #content
        {
            width: 900px;
            margin: 20px auto 0px;
            padding: 0px;
            font-family: "宋体";
            font-size: 12px;
        }
        #content table
        {
            width: 850px;
            margin: 0 auto;
            padding: 20px 0px 0px 20px;
            border: 1px solid #ababab;
        }
        #content td
        {
            height: 30px;
        }
    </style>
</head>
<body>
    <form id="form1" runat="server">
    <div id="container">
        <div id="title">
            <div id="img">
                <img src="../images/img.gif" /></div>
            <div id="logo">
                <img src="../images/qywszc.gif" /></div>
        </div>
        <div id="content">
            <table id="tabData" style="width: 800px;" class="list" cellpadding="1" cellspacing="1">
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        企业名称：
                    </td>
                    <td class="td_right_60">
                        <asp:TextBox ID="Tcomname" runat="server" CssClass="txtbox_300" NotNull="企业名称" InvertedComma="企业名称"
                            ToolTip="请填写企业完整名称"> </asp:TextBox>（请填写企业完整名称）
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        企业类型：
                    </td>
                    <td class="td_right_60">
                        <asp:RadioButtonList ID="RadioButtonList1" runat="server" RepeatLayout="Flow" RepeatDirection="Horizontal"
                            Width="400px">
                            <asp:ListItem Selected="True" Value="0">生产企业</asp:ListItem>
                            <asp:ListItem Value="2">进口药品国内一级代理</asp:ListItem>
                            <asp:ListItem Value="1">经营企业</asp:ListItem>
                        </asp:RadioButtonList>
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        用户名：
                    </td>
                    <td class="td_right_60">
                        <asp:TextBox ID="Tuser" runat="server" CssClass="txtbox_150" NotNull="用户名" InvertedComma="用户名"
                            onkeyup="value=ReplaceNumberOnlyChar(value);"></asp:TextBox>
                        <div id="div1" style="display: none; font-size: 16px; vertical-align: middle; color: white;
                            padding-top: 2px; height: 24px; background-color: red">
                        </div>
                        (用户名必须是字母与数字的组合)
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        密码：
                    </td>
                    <td class="td_right_60">
                        <asp:TextBox ID="Tpwd" runat="server" TextMode="Password" CssClass="txtbox_150" NotNull="密码"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        密码确认：
                    </td>
                    <td class="td_right_60">
                        <asp:TextBox ID="Tpwd2" runat="server" TextMode="Password" CssClass="txtbox_150"
                            NotNull="密码确认"></asp:TextBox>
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;" class="td_left_40">
                        识别码：
                    </td>
                    <td class="td_right_60">
                        <asp:Label ID="Label1" runat="server" Text=""></asp:Label>
                        <asp:HiddenField ID="HiddenField1" runat="server" />
                    </td>
                </tr>
                <tr>
                    <td colspan="2" class="td_center">
                        <asp:Button ID="Button1" runat="server" Text="提 交" CssClass="button_80" OnClientClick="javascript:return YZ(form);"
                            OnClick="Button1_Click" />
                        <input type="reset" value="清空" class="button_80" />
                    </td>
                </tr>
            </table>
        </div>
    </div>
    </form>
</body>
</html>
